#pragma once

#include "mesh.h"
#include <assimp/mesh.h>
#include <assimp/scene.h>

class CModel {

public:
    CModel() = default;
    ~CModel();

    bool LoadModel(const std::string &path);

    void Draw();

private:
    /**
     * @brief 递归的方式处理节点
     */
    void ProcessNode(aiNode *node, const aiScene *scene);

    CMesh ProcessMesh(aiMesh *mesh, const aiScene *scene);

private:
    std::vector<CMesh> m_meshes;
};